import java.io.File;
import java.net.URL;
import java.net.URLDecoder;

public class Main {
	public static File getResourceFile(Class clazz,String resourceFileName){
		URL url = clazz.getResource(resourceFileName);
		String encode = url.getFile();
		String path = null;
		try{
			path = URLDecoder.decode(encode, "UTF-8");
			File file = new File(path);
			if (file.exists()){
				return file;
			}
		}catch (Exception e){
			e.printStackTrace();
		}
		return null;
	}

	public static void main(String[] args) {
		try {
			GeneratorSqlmap generatorSqlmap = new GeneratorSqlmap();
			generatorSqlmap.generator();
			System.out.println("[执行完毕]");
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
}
